-
Notifications
You must be signed in to change notification settings - Fork 5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: 이미지 업로드 API 구현 (#390) #391
Conversation
- Util 은 이미 되어 있었음. 이전 pr에서 수정할때 빼먹어서 그런것 같습니다. - 일반적인 특별한 응답이 없는 서버 통신에서도 judgeStatus 를 사용하고, 반환 타입이 String 인 경우에도 사용하는데 이를 정적인 문자가 아닌 서버에서 넘겨주는 값을 반환하도록 하였습니다.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🫡🫡🫡🫡🫡
let imageData = MultipartFormData(provider: .data(image.pngData() ?? Data()), name: "image", mimeType: "image/png") | ||
multiPartData.append(imageData) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
설명 읽어봤습니당!
뭔가 filename을 포함하지 않는다면 제대로 업로드 되지 않을수도 있겠다는 생각이 들었어요
우리가 스웨거에서 파일을 입력할때는 그야말로 이미 컴퓨터에 존재하는 "png 파일"을 골라서 넣는거라 이미 파일명이 있겠지만,
실제로 사용자가 앱에서 업로드할때는 "파일" 이 아니라 사용자가 갤러리에 가지고 있는 "사진"을 png 파일로 우리가 변환해?주는거라 파일명을 따로 붙여줘야될수도 있겠다는 생각이 들었습니당
근데 이러고 파일 이름 안넣어도 되면 스껄
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
요것도 숫자랑 문자로 이루어진 HEIG 파일명이 존재하는거 같더라구용? 그리고 파라미터가 옵셔널이라서 일단 비워서 한번 테스트해보공!
문제가 있으면 이슈 만들어서 반영해보겠습니당! 고생하셨어요~ 스껄~
🌴 PR 요약
🌱 작업한 브랜치
🌱 작업한 내용
cardImageUpload()
API 를 구현하였습니다. 명함 생성할 때 적용해보겠습니다.참고사항
📮 관련 이슈